<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>spade.XMLCodec</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="spade-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://spade2.googlecode.com">SPADE</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        <a href="spade-module.html">Package&nbsp;spade</a> ::
        Module&nbsp;XMLCodec
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="spade.XMLCodec-pysrc.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<h1 class="epydoc">Source Code for <a href="spade.XMLCodec-module.html">Module spade.XMLCodec</a></h1>
<pre class="py-src">
<a name="L1"></a><tt class="py-lineno">  1</tt>  <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">xml</tt><tt class="py-op">.</tt><tt class="py-name">sax</tt> </tt>
<a name="L2"></a><tt class="py-lineno">  2</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt class="py-name">xml</tt><tt class="py-op">.</tt><tt class="py-name">sax</tt> <tt class="py-keyword">import</tt> <tt class="py-name">handler</tt> </tt>
<a name="L3"></a><tt class="py-lineno">  3</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-0" class="py-name" targets="Module spade.BasicFipaDateTime=spade.BasicFipaDateTime-module.html,Class spade.BasicFipaDateTime.BasicFipaDateTime=spade.BasicFipaDateTime.BasicFipaDateTime-class.html"><a title="spade.BasicFipaDateTime
spade.BasicFipaDateTime.BasicFipaDateTime" class="py-name" href="#" onclick="return doclink('link-0', 'BasicFipaDateTime', 'link-0');">BasicFipaDateTime</a></tt> <tt class="py-keyword">import</tt> <tt class="py-op">*</tt> </tt>
<a name="L4"></a><tt class="py-lineno">  4</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-1" class="py-name" targets="Module spade.AID=spade.AID-module.html"><a title="spade.AID" class="py-name" href="#" onclick="return doclink('link-1', 'AID', 'link-1');">AID</a></tt> <tt class="py-keyword">import</tt> <tt class="py-op">*</tt> </tt>
<a name="L5"></a><tt class="py-lineno">  5</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-2" class="py-name" targets="Module spade.ReceivedObject=spade.ReceivedObject-module.html,Class spade.ReceivedObject.ReceivedObject=spade.ReceivedObject.ReceivedObject-class.html"><a title="spade.ReceivedObject
spade.ReceivedObject.ReceivedObject" class="py-name" href="#" onclick="return doclink('link-2', 'ReceivedObject', 'link-2');">ReceivedObject</a></tt> <tt class="py-keyword">import</tt> <tt id="link-3" class="py-name"><a title="spade.ReceivedObject
spade.ReceivedObject.ReceivedObject" class="py-name" href="#" onclick="return doclink('link-3', 'ReceivedObject', 'link-2');">ReceivedObject</a></tt> </tt>
<a name="L6"></a><tt class="py-lineno">  6</tt>  <tt class="py-line"><tt class="py-keyword">import</tt> <tt id="link-4" class="py-name" targets="Module spade.Envelope=spade.Envelope-module.html,Class spade.Envelope.Envelope=spade.Envelope.Envelope-class.html"><a title="spade.Envelope
spade.Envelope.Envelope" class="py-name" href="#" onclick="return doclink('link-4', 'Envelope', 'link-4');">Envelope</a></tt> </tt>
<a name="L7"></a><tt class="py-lineno">  7</tt>  <tt class="py-line"> </tt>
<a name="L8"></a><tt class="py-lineno">  8</tt>  <tt class="py-line"> </tt>
<a name="L9"></a><tt class="py-lineno">  9</tt>  <tt class="py-line"> </tt>
<a name="XMLCodec"></a><div id="XMLCodec-def"><a name="L10"></a><tt class="py-lineno"> 10</tt> <a class="py-toggle" href="#" id="XMLCodec-toggle" onclick="return toggle('XMLCodec');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html">XMLCodec</a><tt class="py-op">(</tt><tt class="py-base-class">handler</tt><tt class="py-op">.</tt><tt class="py-base-class">ContentHandler</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec-collapsed" style="display:none;" pad="+++" indent="++++"></div><div id="XMLCodec-expanded"><a name="L11"></a><tt class="py-lineno"> 11</tt>  <tt class="py-line">        <tt class="py-docstring">"""</tt> </tt>
<a name="L12"></a><tt class="py-lineno"> 12</tt>  <tt class="py-line"><tt class="py-docstring">        XML Parser</tt> </tt>
<a name="L13"></a><tt class="py-lineno"> 13</tt>  <tt class="py-line"><tt class="py-docstring">        """</tt> </tt>
<a name="XMLCodec.__init__"></a><div id="XMLCodec.__init__-def"><a name="L14"></a><tt class="py-lineno"> 14</tt> <a class="py-toggle" href="#" id="XMLCodec.__init__-toggle" onclick="return toggle('XMLCodec.__init__');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.__init__-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.__init__-expanded"><a name="L15"></a><tt class="py-lineno"> 15</tt>  <tt class="py-line">                <tt class="py-comment">#self.parser = xmlreader.IncrementalParser()</tt> </tt>
<a name="L16"></a><tt class="py-lineno"> 16</tt>  <tt class="py-line">                <tt class="py-comment">#self.parser.setContentHandler(self)</tt> </tt>
<a name="L17"></a><tt class="py-lineno"> 17</tt>  <tt class="py-line">                <tt class="py-comment">#self.parser.setErrorHandler(self)</tt> </tt>
<a name="L18"></a><tt class="py-lineno"> 18</tt>  <tt class="py-line"> </tt>
<a name="L19"></a><tt class="py-lineno"> 19</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ToTag</tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
<a name="L20"></a><tt class="py-lineno"> 20</tt>  <tt class="py-line">         </tt>
<a name="L21"></a><tt class="py-lineno"> 21</tt>  <tt class="py-line">                <tt class="py-comment">#Constants</tt> </tt>
<a name="L22"></a><tt class="py-lineno"> 22</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ENVELOPE_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"envelope"</tt> </tt>
<a name="L23"></a><tt class="py-lineno"> 23</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PARAMS_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"params"</tt> </tt>
<a name="L24"></a><tt class="py-lineno"> 24</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INDEX</tt> <tt class="py-op">=</tt> <tt class="py-string">"index"</tt> </tt>
<a name="L25"></a><tt class="py-lineno"> 25</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INDEX_ATTR</tt> <tt class="py-op">=</tt> <tt class="py-string">' index="'</tt> </tt>
<a name="L26"></a><tt class="py-lineno"> 26</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"to"</tt> </tt>
<a name="L27"></a><tt class="py-lineno"> 27</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"agent-identifier"</tt> </tt>
<a name="L28"></a><tt class="py-lineno"> 28</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_NAME</tt> <tt class="py-op">=</tt> <tt class="py-string">"name"</tt> </tt>
<a name="L29"></a><tt class="py-lineno"> 29</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_ADDRESSES</tt> <tt class="py-op">=</tt> <tt class="py-string">"addresses"</tt> </tt>
<a name="L30"></a><tt class="py-lineno"> 30</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_ADDRESS</tt> <tt class="py-op">=</tt> <tt class="py-string">"url"</tt> </tt>
<a name="L31"></a><tt class="py-lineno"> 31</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"from"</tt> </tt>
<a name="L32"></a><tt class="py-lineno"> 32</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">COMMENTS_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"comments"</tt> </tt>
<a name="L33"></a><tt class="py-lineno"> 33</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">REPRESENTATION_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"acl-representation"</tt> </tt>
<a name="L34"></a><tt class="py-lineno"> 34</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">LENGTH_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"payload-length"</tt> </tt>
<a name="L35"></a><tt class="py-lineno"> 35</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ENCODING_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"payload-encoding"</tt> </tt>
<a name="L36"></a><tt class="py-lineno"> 36</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">DATE_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"date"</tt> </tt>
<a name="L37"></a><tt class="py-lineno"> 37</tt>  <tt class="py-line">                <tt class="py-comment">#self.ENCRYPTED_TAG = "encrypted"</tt> </tt>
<a name="L38"></a><tt class="py-lineno"> 38</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"intended-receiver"</tt> </tt>
<a name="L39"></a><tt class="py-lineno"> 39</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"received"</tt> </tt>
<a name="L40"></a><tt class="py-lineno"> 40</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_DATE</tt> <tt class="py-op">=</tt> <tt class="py-string">"received-date"</tt> </tt>
<a name="L41"></a><tt class="py-lineno"> 41</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_BY</tt> <tt class="py-op">=</tt> <tt class="py-string">"received-by"</tt> </tt>
<a name="L42"></a><tt class="py-lineno"> 42</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_FROM</tt> <tt class="py-op">=</tt> <tt class="py-string">"received-from"</tt>  </tt>
<a name="L43"></a><tt class="py-lineno"> 43</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ID</tt> <tt class="py-op">=</tt> <tt class="py-string">"received-id"</tt>  </tt>
<a name="L44"></a><tt class="py-lineno"> 44</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_VIA</tt> <tt class="py-op">=</tt> <tt class="py-string">"received-via"</tt> </tt>
<a name="L45"></a><tt class="py-lineno"> 45</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt> <tt class="py-op">=</tt> <tt class="py-string">"value"</tt> </tt>
<a name="L46"></a><tt class="py-lineno"> 46</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PROP_TAG</tt> <tt class="py-op">=</tt> <tt class="py-string">"user-defined"</tt> </tt>
<a name="L47"></a><tt class="py-lineno"> 47</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PROP_ATTR</tt> <tt class="py-op">=</tt> <tt class="py-string">"href"</tt> </tt>
<a name="L48"></a><tt class="py-lineno"> 48</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PROP_ATTR_TYPE</tt> <tt class="py-op">=</tt> <tt class="py-string">"type"</tt> </tt>
<a name="L49"></a><tt class="py-lineno"> 49</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PROP_STRING_TYPE</tt> <tt class="py-op">=</tt><tt class="py-string">"string"</tt> </tt>
<a name="L50"></a><tt class="py-lineno"> 50</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PROP_BYTE_TYPE</tt><tt class="py-op">=</tt><tt class="py-string">"byte-array"</tt> </tt>
<a name="L51"></a><tt class="py-lineno"> 51</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PROP_SER_TYPE</tt><tt class="py-op">=</tt><tt class="py-string">"serialized"</tt> </tt>
<a name="L52"></a><tt class="py-lineno"> 52</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">=</tt> <tt class="py-string">"&lt;"</tt> </tt>
<a name="L53"></a><tt class="py-lineno"> 53</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">=</tt> <tt class="py-string">"&lt;/"</tt> </tt>
<a name="L54"></a><tt class="py-lineno"> 54</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> <tt class="py-op">=</tt> <tt class="py-string">"&gt;"</tt> </tt>
<a name="L55"></a><tt class="py-lineno"> 55</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">NULL</tt> <tt class="py-op">=</tt> <tt class="py-string">""</tt> </tt>
</div><a name="L56"></a><tt class="py-lineno"> 56</tt>  <tt class="py-line">      </tt>
<a name="L57"></a><tt class="py-lineno"> 57</tt>  <tt class="py-line">        <tt class="py-comment">#   ***************************************************</tt> </tt>
<a name="L58"></a><tt class="py-lineno"> 58</tt>  <tt class="py-line">        <tt class="py-comment">#   *               Encoding methods                  *</tt> </tt>
<a name="L59"></a><tt class="py-lineno"> 59</tt>  <tt class="py-line">        <tt class="py-comment">#   ***************************************************</tt> </tt>
<a name="L60"></a><tt class="py-lineno"> 60</tt>  <tt class="py-line"> </tt>
<a name="L61"></a><tt class="py-lineno"> 61</tt>  <tt class="py-line">        <tt class="py-string">""" Encode the information of Agent, Tags To and From """</tt>  </tt>
<a name="XMLCodec.encodeAid"></a><div id="XMLCodec.encodeAid-def"><a name="L62"></a><tt class="py-lineno"> 62</tt> <a class="py-toggle" href="#" id="XMLCodec.encodeAid-toggle" onclick="return toggle('XMLCodec.encodeAid');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#encodeAid">encodeAid</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">agentid</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.encodeAid-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.encodeAid-expanded"><a name="L63"></a><tt class="py-lineno"> 63</tt>  <tt class="py-line">                 </tt>
<a name="L64"></a><tt class="py-lineno"> 64</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">agentid</tt><tt class="py-op">,</tt> <tt id="link-5" class="py-name" targets="Class spade.AID.aid=spade.AID.aid-class.html"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-5', 'aid', 'link-5');">aid</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L65"></a><tt class="py-lineno"> 65</tt>  <tt class="py-line">                        <tt class="py-keyword">return</tt> <tt class="py-string">""</tt> </tt>
<a name="L66"></a><tt class="py-lineno"> 66</tt>  <tt class="py-line"> </tt>
<a name="L67"></a><tt class="py-lineno"> 67</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L68"></a><tt class="py-lineno"> 68</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-6" class="py-name" targets="Method spade.ACLParser.ACLxmlParser.encodeTag()=spade.ACLParser.ACLxmlParser-class.html#encodeTag,Method spade.AID.aid.encodeTag()=spade.AID.aid-class.html#encodeTag,Method spade.RDF0Parser.RDF0Parser.encodeTag()=spade.RDF0Parser.RDF0Parser-class.html#encodeTag,Method spade.XMLCodec.XMLCodec.encodeTag()=spade.XMLCodec.XMLCodec-class.html#encodeTag"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-6', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_NAME</tt><tt class="py-op">,</tt> <tt class="py-name">agentid</tt><tt class="py-op">.</tt><tt id="link-7" class="py-name" targets="Method spade.AID.aid.getName()=spade.AID.aid-class.html#getName,Method spade.Agent.AbstractAgent.getName()=spade.Agent.AbstractAgent-class.html#getName,Method spade.DF.DfAgentDescription.getName()=spade.DF.DfAgentDescription-class.html#getName,Method spade.DF.Service.getName()=spade.DF.Service-class.html#getName,Method spade.DF.ServiceDescription.getName()=spade.DF.ServiceDescription-class.html#getName,Method spade.pyparsing.ParseResults.getName()=spade.pyparsing.ParseResults-class.html#getName,Method spade.xmpp.roster.Roster.getName()=spade.xmpp.roster.Roster-class.html#getName,Method spade.xmpp.simplexml.Node.getName()=spade.xmpp.simplexml.Node-class.html#getName,Method spade.xmppd.modules.muc.Room.getName()=spade.xmppd.modules.muc.Room-class.html#getName,Method spade.xmppd.modules.wq.Group.getName()=spade.xmppd.modules.wq.Group-class.html#getName,Method spade.xmppd.xmppd.Session.getName()=spade.xmppd.xmppd.Session-class.html#getName"><a title="spade.AID.aid.getName
spade.Agent.AbstractAgent.getName
spade.DF.DfAgentDescription.getName
spade.DF.Service.getName
spade.DF.ServiceDescription.getName
spade.pyparsing.ParseResults.getName
spade.xmpp.roster.Roster.getName
spade.xmpp.simplexml.Node.getName
spade.xmppd.modules.muc.Room.getName
spade.xmppd.modules.wq.Group.getName
spade.xmppd.xmppd.Session.getName" class="py-name" href="#" onclick="return doclink('link-7', 'getName', 'link-7');">getName</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L69"></a><tt class="py-lineno"> 69</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_ADDRESSES</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L70"></a><tt class="py-lineno"> 70</tt>  <tt class="py-line">     </tt>
<a name="L71"></a><tt class="py-lineno"> 71</tt>  <tt class="py-line">                <tt class="py-name">addresses</tt> <tt class="py-op">=</tt> <tt class="py-name">agentid</tt><tt class="py-op">.</tt><tt id="link-8" class="py-name" targets="Method spade.AID.aid.getAddresses()=spade.AID.aid-class.html#getAddresses"><a title="spade.AID.aid.getAddresses" class="py-name" href="#" onclick="return doclink('link-8', 'getAddresses', 'link-8');">getAddresses</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L72"></a><tt class="py-lineno"> 72</tt>  <tt class="py-line">                <tt class="py-keyword">for</tt> <tt class="py-name">addr</tt> <tt class="py-keyword">in</tt> <tt class="py-name">addresses</tt><tt class="py-op">:</tt> </tt>
<a name="L73"></a><tt class="py-lineno"> 73</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-9" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-9', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_ADDRESS</tt><tt class="py-op">,</tt> <tt class="py-name">addr</tt> <tt class="py-op">)</tt> </tt>
<a name="L74"></a><tt class="py-lineno"> 74</tt>  <tt class="py-line"> </tt>
<a name="L75"></a><tt class="py-lineno"> 75</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_ADDRESSES</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L76"></a><tt class="py-lineno"> 76</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L77"></a><tt class="py-lineno"> 77</tt>  <tt class="py-line"> </tt>
<a name="L78"></a><tt class="py-lineno"> 78</tt>  <tt class="py-line">                <tt class="py-keyword">return</tt> <tt class="py-name">sb</tt> </tt>
</div><a name="L79"></a><tt class="py-lineno"> 79</tt>  <tt class="py-line"> </tt>
<a name="L80"></a><tt class="py-lineno"> 80</tt>  <tt class="py-line">        <tt class="py-string">"""</tt> </tt>
<a name="L81"></a><tt class="py-lineno"> 81</tt>  <tt class="py-line"><tt class="py-string">          This does the following:</tt> </tt>
<a name="L82"></a><tt class="py-lineno"> 82</tt>  <tt class="py-line"><tt class="py-string">          &lt; tag &gt;</tt> </tt>
<a name="L83"></a><tt class="py-lineno"> 83</tt>  <tt class="py-line"><tt class="py-string">             content</tt> </tt>
<a name="L84"></a><tt class="py-lineno"> 84</tt>  <tt class="py-line"><tt class="py-string">          &lt;/ tag &gt;</tt> </tt>
<a name="L85"></a><tt class="py-lineno"> 85</tt>  <tt class="py-line"><tt class="py-string">        """</tt> </tt>
<a name="XMLCodec.encodeTag"></a><div id="XMLCodec.encodeTag-def"><a name="L86"></a><tt class="py-lineno"> 86</tt> <a class="py-toggle" href="#" id="XMLCodec.encodeTag-toggle" onclick="return toggle('XMLCodec.encodeTag');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#encodeTag">encodeTag</a><tt class="py-op">(</tt> <tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">tag</tt><tt class="py-op">,</tt> <tt class="py-param">content</tt> <tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.encodeTag-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.encodeTag-expanded"><a name="L87"></a><tt class="py-lineno"> 87</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">tag</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L88"></a><tt class="py-lineno"> 88</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt id="link-10" class="py-name" targets="Module spade.content=spade.content-module.html"><a title="spade.content" class="py-name" href="#" onclick="return doclink('link-10', 'content', 'link-10');">content</a></tt> </tt>
<a name="L89"></a><tt class="py-lineno"> 89</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">tag</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L90"></a><tt class="py-lineno"> 90</tt>  <tt class="py-line"> </tt>
<a name="L91"></a><tt class="py-lineno"> 91</tt>  <tt class="py-line">                <tt class="py-keyword">return</tt> <tt class="py-name">sb</tt> </tt>
</div><a name="L92"></a><tt class="py-lineno"> 92</tt>  <tt class="py-line">   </tt>
<a name="L93"></a><tt class="py-lineno"> 93</tt>  <tt class="py-line">        <tt class="py-string">""" </tt> </tt>
<a name="L94"></a><tt class="py-lineno"> 94</tt>  <tt class="py-line"><tt class="py-string">        A user-defined property (String name, Object value) is encoded the following way:</tt> </tt>
<a name="L95"></a><tt class="py-lineno"> 95</tt>  <tt class="py-line"><tt class="py-string">        &lt;user-defined href="name" type="type"&gt;value&lt;/user-defined&gt;</tt> </tt>
<a name="L96"></a><tt class="py-lineno"> 96</tt>  <tt class="py-line"><tt class="py-string">        """</tt> </tt>
<a name="L97"></a><tt class="py-lineno"> 97</tt>  <tt class="py-line">        <tt class="py-string">"""</tt> </tt>
<a name="L98"></a><tt class="py-lineno"> 98</tt>  <tt class="py-line"><tt class="py-string">        def encodeProp( self, prop):</tt> </tt>
<a name="L99"></a><tt class="py-lineno"> 99</tt>  <tt class="py-line"><tt class="py-string">                v = None</tt> </tt>
<a name="L100"></a><tt class="py-lineno">100</tt>  <tt class="py-line"><tt class="py-string">                Object o = p.getValue();</tt> </tt>
<a name="L101"></a><tt class="py-lineno">101</tt>  <tt class="py-line"><tt class="py-string">                String type = PROP_STRING_TYPE;</tt> </tt>
<a name="L102"></a><tt class="py-lineno">102</tt>  <tt class="py-line"><tt class="py-string">                if (o instanceof String) {</tt> </tt>
<a name="L103"></a><tt class="py-lineno">103</tt>  <tt class="py-line"><tt class="py-string">                v = (String)o;</tt> </tt>
<a name="L104"></a><tt class="py-lineno">104</tt>  <tt class="py-line"><tt class="py-string">                }</tt> </tt>
<a name="L105"></a><tt class="py-lineno">105</tt>  <tt class="py-line"><tt class="py-string">                else if (o instanceof byte[]) {</tt> </tt>
<a name="L106"></a><tt class="py-lineno">106</tt>  <tt class="py-line"><tt class="py-string">                type = PROP_BYTE_TYPE;</tt> </tt>
<a name="L107"></a><tt class="py-lineno">107</tt>  <tt class="py-line"><tt class="py-string">                v = new String(Base64.encode((byte[])o));</tt> </tt>
<a name="L108"></a><tt class="py-lineno">108</tt>  <tt class="py-line"><tt class="py-string">                }</tt> </tt>
<a name="L109"></a><tt class="py-lineno">109</tt>  <tt class="py-line"><tt class="py-string">                else if (o instanceof Serializable) {</tt> </tt>
<a name="L110"></a><tt class="py-lineno">110</tt>  <tt class="py-line"><tt class="py-string">                type = PROP_SER_TYPE;</tt> </tt>
<a name="L111"></a><tt class="py-lineno">111</tt>  <tt class="py-line"><tt class="py-string">                try{</tt> </tt>
<a name="L112"></a><tt class="py-lineno">112</tt>  <tt class="py-line"><tt class="py-string">                ByteArrayOutputStream bos = new ByteArrayOutputStream();</tt> </tt>
<a name="L113"></a><tt class="py-lineno">113</tt>  <tt class="py-line"><tt class="py-string">                ObjectOutputStream oos = new ObjectOutputStream(bos);</tt> </tt>
<a name="L114"></a><tt class="py-lineno">114</tt>  <tt class="py-line"><tt class="py-string">                oos.writeObject(o);</tt> </tt>
<a name="L115"></a><tt class="py-lineno">115</tt>  <tt class="py-line"><tt class="py-string">                oos.close();</tt> </tt>
<a name="L116"></a><tt class="py-lineno">116</tt>  <tt class="py-line"><tt class="py-string">                byte[] bytes = bos.toByteArray();</tt> </tt>
<a name="L117"></a><tt class="py-lineno">117</tt>  <tt class="py-line"><tt class="py-string">                if(bytes != null)</tt> </tt>
<a name="L118"></a><tt class="py-lineno">118</tt>  <tt class="py-line"><tt class="py-string">                v = new String(Base64.encode(bytes));</tt> </tt>
<a name="L119"></a><tt class="py-lineno">119</tt>  <tt class="py-line"><tt class="py-string">                }catch(IOException ioe){</tt> </tt>
<a name="L120"></a><tt class="py-lineno">120</tt>  <tt class="py-line"><tt class="py-string">                return;</tt> </tt>
<a name="L121"></a><tt class="py-lineno">121</tt>  <tt class="py-line"><tt class="py-string">                }</tt> </tt>
<a name="L122"></a><tt class="py-lineno">122</tt>  <tt class="py-line"><tt class="py-string">                }</tt> </tt>
<a name="L123"></a><tt class="py-lineno">123</tt>  <tt class="py-line"><tt class="py-string">                else {</tt> </tt>
<a name="L124"></a><tt class="py-lineno">124</tt>  <tt class="py-line"><tt class="py-string">                return;</tt> </tt>
<a name="L125"></a><tt class="py-lineno">125</tt>  <tt class="py-line"><tt class="py-string">                }</tt> </tt>
<a name="L126"></a><tt class="py-lineno">126</tt>  <tt class="py-line"><tt class="py-string">                sb.append(OT).append(PROP_TAG).append(" ");</tt> </tt>
<a name="L127"></a><tt class="py-lineno">127</tt>  <tt class="py-line"><tt class="py-string">                sb.append(PROP_ATTR).append("=\"").append(p.getName()).append("\" ");</tt> </tt>
<a name="L128"></a><tt class="py-lineno">128</tt>  <tt class="py-line"><tt class="py-string">                sb.append(PROP_ATTR_TYPE).append("=\"").append(type).append("\"");</tt> </tt>
<a name="L129"></a><tt class="py-lineno">129</tt>  <tt class="py-line"><tt class="py-string">                sb.append(CT);</tt> </tt>
<a name="L130"></a><tt class="py-lineno">130</tt>  <tt class="py-line"><tt class="py-string">                sb.append(v);</tt> </tt>
<a name="L131"></a><tt class="py-lineno">131</tt>  <tt class="py-line"><tt class="py-string">                sb.append(ET).append(PROP_TAG).append(CT);</tt> </tt>
<a name="L132"></a><tt class="py-lineno">132</tt>  <tt class="py-line"><tt class="py-string">                }</tt> </tt>
<a name="L133"></a><tt class="py-lineno">133</tt>  <tt class="py-line"><tt class="py-string">  private void decodeProp(StringBuffer acc, Property p) {</tt> </tt>
<a name="L134"></a><tt class="py-lineno">134</tt>  <tt class="py-line"><tt class="py-string">    if(propType.equals(PROP_SER_TYPE)){</tt> </tt>
<a name="L135"></a><tt class="py-lineno">135</tt>  <tt class="py-line"><tt class="py-string">      try{</tt> </tt>
<a name="L136"></a><tt class="py-lineno">136</tt>  <tt class="py-line"><tt class="py-string">        char[] serdata = acc.toString().toCharArray();</tt> </tt>
<a name="L137"></a><tt class="py-lineno">137</tt>  <tt class="py-line"><tt class="py-string">        ObjectInputStream ois = new ObjectInputStream( </tt> </tt>
<a name="L138"></a><tt class="py-lineno">138</tt>  <tt class="py-line"><tt class="py-string">          new ByteArrayInputStream(Base64.decode(serdata)));</tt> </tt>
<a name="L139"></a><tt class="py-lineno">139</tt>  <tt class="py-line"><tt class="py-string">        p.setValue((Serializable)ois.readObject());</tt> </tt>
<a name="L140"></a><tt class="py-lineno">140</tt>  <tt class="py-line"><tt class="py-string">      }catch(Exception e){</tt> </tt>
<a name="L141"></a><tt class="py-lineno">141</tt>  <tt class="py-line"><tt class="py-string">          // nothing, we leave value of this property as null;</tt> </tt>
<a name="L142"></a><tt class="py-lineno">142</tt>  <tt class="py-line"><tt class="py-string">      }</tt> </tt>
<a name="L143"></a><tt class="py-lineno">143</tt>  <tt class="py-line"><tt class="py-string">    }else if(propType.equals(PROP_BYTE_TYPE)){</tt> </tt>
<a name="L144"></a><tt class="py-lineno">144</tt>  <tt class="py-line"><tt class="py-string">      char[] bytes = acc.toString().toCharArray();</tt> </tt>
<a name="L145"></a><tt class="py-lineno">145</tt>  <tt class="py-line"><tt class="py-string">      p.setValue(Base64.decode(bytes));</tt> </tt>
<a name="L146"></a><tt class="py-lineno">146</tt>  <tt class="py-line"><tt class="py-string">    }else{</tt> </tt>
<a name="L147"></a><tt class="py-lineno">147</tt>  <tt class="py-line"><tt class="py-string">      p.setValue(acc.toString());</tt> </tt>
<a name="L148"></a><tt class="py-lineno">148</tt>  <tt class="py-line"><tt class="py-string">    }</tt> </tt>
<a name="L149"></a><tt class="py-lineno">149</tt>  <tt class="py-line"><tt class="py-string">    propType = null;</tt> </tt>
<a name="L150"></a><tt class="py-lineno">150</tt>  <tt class="py-line"><tt class="py-string">  }</tt> </tt>
<a name="L151"></a><tt class="py-lineno">151</tt>  <tt class="py-line"><tt class="py-string">"""</tt> </tt>
<a name="L152"></a><tt class="py-lineno">152</tt>  <tt class="py-line">  </tt>
<a name="XMLCodec.encodeOneLineTag"></a><div id="XMLCodec.encodeOneLineTag-def"><a name="L153"></a><tt class="py-lineno">153</tt> <a class="py-toggle" href="#" id="XMLCodec.encodeOneLineTag-toggle" onclick="return toggle('XMLCodec.encodeOneLineTag');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#encodeOneLineTag">encodeOneLineTag</a><tt class="py-op">(</tt> <tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">tag1</tt><tt class="py-op">,</tt> <tt class="py-param">tag2</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt> <tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.encodeOneLineTag-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.encodeOneLineTag-expanded"><a name="L154"></a><tt class="py-lineno">154</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">tag1</tt> <tt class="py-op">+</tt> <tt class="py-string">" "</tt> </tt>
<a name="L155"></a><tt class="py-lineno">155</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">tag2</tt> <tt class="py-op">+</tt> <tt class="py-string">'="'</tt> <tt class="py-op">+</tt> <tt class="py-name">value</tt> <tt class="py-op">+</tt> <tt class="py-string">'"/&gt;'</tt> </tt>
<a name="L156"></a><tt class="py-lineno">156</tt>  <tt class="py-line"> </tt>
<a name="L157"></a><tt class="py-lineno">157</tt>  <tt class="py-line">                <tt class="py-keyword">return</tt> <tt class="py-name">sb</tt>  </tt>
</div><a name="L158"></a><tt class="py-lineno">158</tt>  <tt class="py-line">   </tt>
<a name="XMLCodec.encodeXML"></a><div id="XMLCodec.encodeXML-def"><a name="L159"></a><tt class="py-lineno">159</tt> <a class="py-toggle" href="#" id="XMLCodec.encodeXML-toggle" onclick="return toggle('XMLCodec.encodeXML');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#encodeXML">encodeXML</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">env</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.encodeXML-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.encodeXML-expanded"><a name="L160"></a><tt class="py-lineno">160</tt>  <tt class="py-line">                <tt class="py-docstring">"""</tt> </tt>
<a name="L161"></a><tt class="py-lineno">161</tt>  <tt class="py-line"><tt class="py-docstring">                General Encoding of the envelope</tt> </tt>
<a name="L162"></a><tt class="py-lineno">162</tt>  <tt class="py-line"><tt class="py-docstring">                """</tt> </tt>
<a name="L163"></a><tt class="py-lineno">163</tt>  <tt class="py-line">      </tt>
<a name="L164"></a><tt class="py-lineno">164</tt>  <tt class="py-line">                <tt class="py-comment">#Create the message XML</tt> </tt>
<a name="L165"></a><tt class="py-lineno">165</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ENVELOPE_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L166"></a><tt class="py-lineno">166</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PARAMS_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INDEX_ATTR</tt> <tt class="py-op">+</tt> <tt class="py-string">"1"</tt> <tt class="py-op">+</tt> <tt class="py-string">'"'</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L167"></a><tt class="py-lineno">167</tt>  <tt class="py-line">     </tt>
<a name="L168"></a><tt class="py-lineno">168</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag TO</tt> </tt>
<a name="L169"></a><tt class="py-lineno">169</tt>  <tt class="py-line">                <tt class="py-name">tos</tt> <tt class="py-op">=</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-11" class="py-name" targets="Method spade.Envelope.Envelope.getTo()=spade.Envelope.Envelope-class.html#getTo,Method spade.xmpp.protocol.Protocol.getTo()=spade.xmpp.protocol.Protocol-class.html#getTo"><a title="spade.Envelope.Envelope.getTo
spade.xmpp.protocol.Protocol.getTo" class="py-name" href="#" onclick="return doclink('link-11', 'getTo', 'link-11');">getTo</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L170"></a><tt class="py-lineno">170</tt>  <tt class="py-line">                <tt class="py-keyword">for</tt> <tt class="py-name">agentid</tt> <tt class="py-keyword">in</tt> <tt class="py-name">tos</tt><tt class="py-op">:</tt> </tt>
<a name="L171"></a><tt class="py-lineno">171</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L172"></a><tt class="py-lineno">172</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-12" class="py-name" targets="Method spade.ACLParser.ACLxmlParser.encodeAid()=spade.ACLParser.ACLxmlParser-class.html#encodeAid,Method spade.XMLCodec.XMLCodec.encodeAid()=spade.XMLCodec.XMLCodec-class.html#encodeAid"><a title="spade.ACLParser.ACLxmlParser.encodeAid
spade.XMLCodec.XMLCodec.encodeAid" class="py-name" href="#" onclick="return doclink('link-12', 'encodeAid', 'link-12');">encodeAid</a></tt><tt class="py-op">(</tt><tt class="py-name">agentid</tt><tt class="py-op">)</tt> </tt>
<a name="L173"></a><tt class="py-lineno">173</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L174"></a><tt class="py-lineno">174</tt>  <tt class="py-line">     </tt>
<a name="L175"></a><tt class="py-lineno">175</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag from</tt> </tt>
<a name="L176"></a><tt class="py-lineno">176</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-13" class="py-name" targets="Method spade.Envelope.Envelope.getFrom()=spade.Envelope.Envelope-class.html#getFrom,Method spade.ReceivedObject.ReceivedObject.getFrom()=spade.ReceivedObject.ReceivedObject-class.html#getFrom,Method spade.xmpp.protocol.Protocol.getFrom()=spade.xmpp.protocol.Protocol-class.html#getFrom"><a title="spade.Envelope.Envelope.getFrom
spade.ReceivedObject.ReceivedObject.getFrom
spade.xmpp.protocol.Protocol.getFrom" class="py-name" href="#" onclick="return doclink('link-13', 'getFrom', 'link-13');">getFrom</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L177"></a><tt class="py-lineno">177</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L178"></a><tt class="py-lineno">178</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-14" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeAid
spade.XMLCodec.XMLCodec.encodeAid" class="py-name" href="#" onclick="return doclink('link-14', 'encodeAid', 'link-12');">encodeAid</a></tt><tt class="py-op">(</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-15" class="py-name"><a title="spade.Envelope.Envelope.getFrom
spade.ReceivedObject.ReceivedObject.getFrom
spade.xmpp.protocol.Protocol.getFrom" class="py-name" href="#" onclick="return doclink('link-15', 'getFrom', 'link-13');">getFrom</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L179"></a><tt class="py-lineno">179</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L180"></a><tt class="py-lineno">180</tt>  <tt class="py-line">     </tt>
<a name="L181"></a><tt class="py-lineno">181</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag comments</tt> </tt>
<a name="L182"></a><tt class="py-lineno">182</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-16" class="py-name" targets="Method spade.Envelope.Envelope.getComments()=spade.Envelope.Envelope-class.html#getComments"><a title="spade.Envelope.Envelope.getComments" class="py-name" href="#" onclick="return doclink('link-16', 'getComments', 'link-16');">getComments</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-17" class="py-name"><a title="spade.Envelope.Envelope.getComments" class="py-name" href="#" onclick="return doclink('link-17', 'getComments', 'link-16');">getComments</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
<a name="L183"></a><tt class="py-lineno">183</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-18" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-18', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">COMMENTS_TAG</tt><tt class="py-op">,</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-19" class="py-name"><a title="spade.Envelope.Envelope.getComments" class="py-name" href="#" onclick="return doclink('link-19', 'getComments', 'link-16');">getComments</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L184"></a><tt class="py-lineno">184</tt>  <tt class="py-line">     </tt>
<a name="L185"></a><tt class="py-lineno">185</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag acl-representation</tt> </tt>
<a name="L186"></a><tt class="py-lineno">186</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-20" class="py-name" targets="Method spade.Envelope.Envelope.getAclRepresentation()=spade.Envelope.Envelope-class.html#getAclRepresentation"><a title="spade.Envelope.Envelope.getAclRepresentation" class="py-name" href="#" onclick="return doclink('link-20', 'getAclRepresentation', 'link-20');">getAclRepresentation</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L187"></a><tt class="py-lineno">187</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-21" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-21', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">REPRESENTATION_TAG</tt><tt class="py-op">,</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-22" class="py-name"><a title="spade.Envelope.Envelope.getAclRepresentation" class="py-name" href="#" onclick="return doclink('link-22', 'getAclRepresentation', 'link-20');">getAclRepresentation</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L188"></a><tt class="py-lineno">188</tt>  <tt class="py-line">     </tt>
<a name="L189"></a><tt class="py-lineno">189</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag payload-length</tt> </tt>
<a name="L190"></a><tt class="py-lineno">190</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-23" class="py-name" targets="Method spade.Envelope.Envelope.getPayloadLength()=spade.Envelope.Envelope-class.html#getPayloadLength"><a title="spade.Envelope.Envelope.getPayloadLength" class="py-name" href="#" onclick="return doclink('link-23', 'getPayloadLength', 'link-23');">getPayloadLength</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L191"></a><tt class="py-lineno">191</tt>  <tt class="py-line">                                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-24" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-24', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">LENGTH_TAG</tt><tt class="py-op">,</tt> <tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-25" class="py-name"><a title="spade.Envelope.Envelope.getPayloadLength" class="py-name" href="#" onclick="return doclink('link-25', 'getPayloadLength', 'link-23');">getPayloadLength</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L192"></a><tt class="py-lineno">192</tt>  <tt class="py-line">     </tt>
<a name="L193"></a><tt class="py-lineno">193</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag payload-encoding</tt> </tt>
<a name="L194"></a><tt class="py-lineno">194</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-26" class="py-name" targets="Method spade.Envelope.Envelope.getPayloadEncoding()=spade.Envelope.Envelope-class.html#getPayloadEncoding"><a title="spade.Envelope.Envelope.getPayloadEncoding" class="py-name" href="#" onclick="return doclink('link-26', 'getPayloadEncoding', 'link-26');">getPayloadEncoding</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-27" class="py-name"><a title="spade.Envelope.Envelope.getPayloadEncoding" class="py-name" href="#" onclick="return doclink('link-27', 'getPayloadEncoding', 'link-26');">getPayloadEncoding</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
<a name="L195"></a><tt class="py-lineno">195</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-28" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-28', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ENCODING_TAG</tt><tt class="py-op">,</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-29" class="py-name"><a title="spade.Envelope.Envelope.getPayloadEncoding" class="py-name" href="#" onclick="return doclink('link-29', 'getPayloadEncoding', 'link-26');">getPayloadEncoding</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L196"></a><tt class="py-lineno">196</tt>  <tt class="py-line">     </tt>
<a name="L197"></a><tt class="py-lineno">197</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag date</tt> </tt>
<a name="L198"></a><tt class="py-lineno">198</tt>  <tt class="py-line">                <tt class="py-comment">#Create object BasicFipaDateTime</tt> </tt>
<a name="L199"></a><tt class="py-lineno">199</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-30" class="py-name" targets="Method spade.BasicFipaDateTime.BasicFipaDateTime.getDate()=spade.BasicFipaDateTime.BasicFipaDateTime-class.html#getDate,Method spade.Envelope.Envelope.getDate()=spade.Envelope.Envelope-class.html#getDate,Method spade.ReceivedObject.ReceivedObject.getDate()=spade.ReceivedObject.ReceivedObject-class.html#getDate"><a title="spade.BasicFipaDateTime.BasicFipaDateTime.getDate
spade.Envelope.Envelope.getDate
spade.ReceivedObject.ReceivedObject.getDate" class="py-name" href="#" onclick="return doclink('link-30', 'getDate', 'link-30');">getDate</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L200"></a><tt class="py-lineno">200</tt>  <tt class="py-line">                        <tt class="py-name">date</tt> <tt class="py-op">=</tt> <tt id="link-31" class="py-name"><a title="spade.BasicFipaDateTime
spade.BasicFipaDateTime.BasicFipaDateTime" class="py-name" href="#" onclick="return doclink('link-31', 'BasicFipaDateTime', 'link-0');">BasicFipaDateTime</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L201"></a><tt class="py-lineno">201</tt>  <tt class="py-line">                        <tt class="py-name">date</tt><tt class="py-op">.</tt><tt id="link-32" class="py-name" targets="Method spade.BasicFipaDateTime.BasicFipaDateTime.fromString()=spade.BasicFipaDateTime.BasicFipaDateTime-class.html#fromString"><a title="spade.BasicFipaDateTime.BasicFipaDateTime.fromString" class="py-name" href="#" onclick="return doclink('link-32', 'fromString', 'link-32');">fromString</a></tt><tt class="py-op">(</tt> <tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-33" class="py-name"><a title="spade.BasicFipaDateTime.BasicFipaDateTime.getDate
spade.Envelope.Envelope.getDate
spade.ReceivedObject.ReceivedObject.getDate" class="py-name" href="#" onclick="return doclink('link-33', 'getDate', 'link-30');">getDate</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L202"></a><tt class="py-lineno">202</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-34" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeTag
spade.AID.aid.encodeTag
spade.RDF0Parser.RDF0Parser.encodeTag
spade.XMLCodec.XMLCodec.encodeTag" class="py-name" href="#" onclick="return doclink('link-34', 'encodeTag', 'link-6');">encodeTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">DATE_TAG</tt><tt class="py-op">,</tt> <tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">date</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L203"></a><tt class="py-lineno">203</tt>  <tt class="py-line"> </tt>
<a name="L204"></a><tt class="py-lineno">204</tt>  <tt class="py-line">     </tt>
<a name="L205"></a><tt class="py-lineno">205</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag encrypted (NL: not sure it is still in FIPA)</tt> </tt>
<a name="L206"></a><tt class="py-lineno">206</tt>  <tt class="py-line">                <tt class="py-string">"""</tt> </tt>
<a name="L207"></a><tt class="py-lineno">207</tt>  <tt class="py-line"><tt class="py-string">                for i in env.getEncrypted():</tt> </tt>
<a name="L208"></a><tt class="py-lineno">208</tt>  <tt class="py-line"><tt class="py-string">                        sb = sb + self.encodeTag( self.ENCRYPTED_TAG, str(i) )  </tt> </tt>
<a name="L209"></a><tt class="py-lineno">209</tt>  <tt class="py-line"><tt class="py-string">                """</tt> </tt>
<a name="L210"></a><tt class="py-lineno">210</tt>  <tt class="py-line">     </tt>
<a name="L211"></a><tt class="py-lineno">211</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag intended-receiver</tt> </tt>
<a name="L212"></a><tt class="py-lineno">212</tt>  <tt class="py-line">                <tt class="py-keyword">for</tt> <tt class="py-name">i</tt> <tt class="py-keyword">in</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-35" class="py-name" targets="Method spade.Envelope.Envelope.getIntendedReceiver()=spade.Envelope.Envelope-class.html#getIntendedReceiver"><a title="spade.Envelope.Envelope.getIntendedReceiver" class="py-name" href="#" onclick="return doclink('link-35', 'getIntendedReceiver', 'link-35');">getIntendedReceiver</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L213"></a><tt class="py-lineno">213</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L214"></a><tt class="py-lineno">214</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-36" class="py-name"><a title="spade.ACLParser.ACLxmlParser.encodeAid
spade.XMLCodec.XMLCodec.encodeAid" class="py-name" href="#" onclick="return doclink('link-36', 'encodeAid', 'link-12');">encodeAid</a></tt><tt class="py-op">(</tt><tt class="py-name">i</tt><tt class="py-op">)</tt> </tt>
<a name="L215"></a><tt class="py-lineno">215</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L216"></a><tt class="py-lineno">216</tt>  <tt class="py-line">           </tt>
<a name="L217"></a><tt class="py-lineno">217</tt>  <tt class="py-line">                <tt class="py-string">"""</tt> </tt>
<a name="L218"></a><tt class="py-lineno">218</tt>  <tt class="py-line"><tt class="py-string">                #Create tags for user properties</tt> </tt>
<a name="L219"></a><tt class="py-lineno">219</tt>  <tt class="py-line"><tt class="py-string">                for (i=env.getAllProperties();i.hasNext();) {</tt> </tt>
<a name="L220"></a><tt class="py-lineno">220</tt>  <tt class="py-line"><tt class="py-string">                        encodeProp(sb,(Property)i.next());</tt> </tt>
<a name="L221"></a><tt class="py-lineno">221</tt>  <tt class="py-line"><tt class="py-string">                """</tt> </tt>
<a name="L222"></a><tt class="py-lineno">222</tt>  <tt class="py-line"> </tt>
<a name="L223"></a><tt class="py-lineno">223</tt>  <tt class="py-line">                <tt class="py-comment">#Create tag received</tt> </tt>
<a name="L224"></a><tt class="py-lineno">224</tt>  <tt class="py-line">                <tt class="py-name">ro</tt> <tt class="py-op">=</tt> <tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-37" class="py-name" targets="Method spade.Envelope.Envelope.getReceived()=spade.Envelope.Envelope-class.html#getReceived"><a title="spade.Envelope.Envelope.getReceived" class="py-name" href="#" onclick="return doclink('link-37', 'getReceived', 'link-37');">getReceived</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L225"></a><tt class="py-lineno">225</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">ro</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L226"></a><tt class="py-lineno">226</tt>  <tt class="py-line">                        <tt class="py-comment">#Create tag received</tt> </tt>
<a name="L227"></a><tt class="py-lineno">227</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">OT</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L228"></a><tt class="py-lineno">228</tt>  <tt class="py-line">                        <tt class="py-comment">#Date  </tt> </tt>
<a name="L229"></a><tt class="py-lineno">229</tt>  <tt class="py-line">                        <tt class="py-name">value</tt> <tt class="py-op">=</tt> <tt id="link-38" class="py-name"><a title="spade.BasicFipaDateTime
spade.BasicFipaDateTime.BasicFipaDateTime" class="py-name" href="#" onclick="return doclink('link-38', 'BasicFipaDateTime', 'link-0');">BasicFipaDateTime</a></tt><tt class="py-op">(</tt> <tt class="py-name">ro</tt><tt class="py-op">.</tt><tt id="link-39" class="py-name"><a title="spade.BasicFipaDateTime.BasicFipaDateTime.getDate
spade.Envelope.Envelope.getDate
spade.ReceivedObject.ReceivedObject.getDate" class="py-name" href="#" onclick="return doclink('link-39', 'getDate', 'link-30');">getDate</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L230"></a><tt class="py-lineno">230</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">value</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L231"></a><tt class="py-lineno">231</tt>  <tt class="py-line">                                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-40" class="py-name" targets="Method spade.RDF0Parser.RDF0Parser.encodeOneLineTag()=spade.RDF0Parser.RDF0Parser-class.html#encodeOneLineTag,Method spade.XMLCodec.XMLCodec.encodeOneLineTag()=spade.XMLCodec.XMLCodec-class.html#encodeOneLineTag"><a title="spade.RDF0Parser.RDF0Parser.encodeOneLineTag
spade.XMLCodec.XMLCodec.encodeOneLineTag" class="py-name" href="#" onclick="return doclink('link-40', 'encodeOneLineTag', 'link-40');">encodeOneLineTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_DATE</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">,</tt> <tt class="py-name">str</tt><tt class="py-op">(</tt> <tt class="py-name">value</tt> <tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L232"></a><tt class="py-lineno">232</tt>  <tt class="py-line">                        <tt class="py-comment">#By</tt> </tt>
<a name="L233"></a><tt class="py-lineno">233</tt>  <tt class="py-line">                        <tt class="py-name">value</tt> <tt class="py-op">=</tt> <tt class="py-name">ro</tt><tt class="py-op">.</tt><tt id="link-41" class="py-name" targets="Method spade.ReceivedObject.ReceivedObject.getBy()=spade.ReceivedObject.ReceivedObject-class.html#getBy"><a title="spade.ReceivedObject.ReceivedObject.getBy" class="py-name" href="#" onclick="return doclink('link-41', 'getBy', 'link-41');">getBy</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L234"></a><tt class="py-lineno">234</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">value</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L235"></a><tt class="py-lineno">235</tt>  <tt class="py-line">                                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-42" class="py-name"><a title="spade.RDF0Parser.RDF0Parser.encodeOneLineTag
spade.XMLCodec.XMLCodec.encodeOneLineTag" class="py-name" href="#" onclick="return doclink('link-42', 'encodeOneLineTag', 'link-40');">encodeOneLineTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_BY</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">,</tt> <tt class="py-name">value</tt> <tt class="py-op">)</tt> </tt>
<a name="L236"></a><tt class="py-lineno">236</tt>  <tt class="py-line">                        <tt class="py-comment">#From</tt> </tt>
<a name="L237"></a><tt class="py-lineno">237</tt>  <tt class="py-line">                        <tt class="py-name">value</tt> <tt class="py-op">=</tt> <tt class="py-name">ro</tt><tt class="py-op">.</tt><tt id="link-43" class="py-name"><a title="spade.Envelope.Envelope.getFrom
spade.ReceivedObject.ReceivedObject.getFrom
spade.xmpp.protocol.Protocol.getFrom" class="py-name" href="#" onclick="return doclink('link-43', 'getFrom', 'link-13');">getFrom</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L238"></a><tt class="py-lineno">238</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">value</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L239"></a><tt class="py-lineno">239</tt>  <tt class="py-line">                                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-44" class="py-name"><a title="spade.RDF0Parser.RDF0Parser.encodeOneLineTag
spade.XMLCodec.XMLCodec.encodeOneLineTag" class="py-name" href="#" onclick="return doclink('link-44', 'encodeOneLineTag', 'link-40');">encodeOneLineTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_FROM</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">,</tt> <tt class="py-name">value</tt> <tt class="py-op">)</tt> </tt>
<a name="L240"></a><tt class="py-lineno">240</tt>  <tt class="py-line">                        <tt class="py-comment">#Id</tt> </tt>
<a name="L241"></a><tt class="py-lineno">241</tt>  <tt class="py-line">                        <tt class="py-name">value</tt> <tt class="py-op">=</tt> <tt class="py-name">ro</tt><tt class="py-op">.</tt><tt id="link-45" class="py-name" targets="Method spade.ReceivedObject.ReceivedObject.getId()=spade.ReceivedObject.ReceivedObject-class.html#getId"><a title="spade.ReceivedObject.ReceivedObject.getId" class="py-name" href="#" onclick="return doclink('link-45', 'getId', 'link-45');">getId</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L242"></a><tt class="py-lineno">242</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">value</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L243"></a><tt class="py-lineno">243</tt>  <tt class="py-line">                                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-46" class="py-name"><a title="spade.RDF0Parser.RDF0Parser.encodeOneLineTag
spade.XMLCodec.XMLCodec.encodeOneLineTag" class="py-name" href="#" onclick="return doclink('link-46', 'encodeOneLineTag', 'link-40');">encodeOneLineTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ID</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">,</tt> <tt class="py-name">value</tt> <tt class="py-op">)</tt> </tt>
<a name="L244"></a><tt class="py-lineno">244</tt>  <tt class="py-line">                        <tt class="py-comment">#Via</tt> </tt>
<a name="L245"></a><tt class="py-lineno">245</tt>  <tt class="py-line">                        <tt class="py-name">value</tt> <tt class="py-op">=</tt> <tt class="py-name">ro</tt><tt class="py-op">.</tt><tt id="link-47" class="py-name" targets="Method spade.ReceivedObject.ReceivedObject.getVia()=spade.ReceivedObject.ReceivedObject-class.html#getVia"><a title="spade.ReceivedObject.ReceivedObject.getVia" class="py-name" href="#" onclick="return doclink('link-47', 'getVia', 'link-47');">getVia</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L246"></a><tt class="py-lineno">246</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">value</tt> <tt class="py-op">!=</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L247"></a><tt class="py-lineno">247</tt>  <tt class="py-line">                                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-48" class="py-name"><a title="spade.RDF0Parser.RDF0Parser.encodeOneLineTag
spade.XMLCodec.XMLCodec.encodeOneLineTag" class="py-name" href="#" onclick="return doclink('link-48', 'encodeOneLineTag', 'link-40');">encodeOneLineTag</a></tt><tt class="py-op">(</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_VIA</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">,</tt> <tt class="py-name">value</tt> <tt class="py-op">)</tt> </tt>
<a name="L248"></a><tt class="py-lineno">248</tt>  <tt class="py-line"> </tt>
<a name="L249"></a><tt class="py-lineno">249</tt>  <tt class="py-line">                        <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt>  </tt>
<a name="L250"></a><tt class="py-lineno">250</tt>  <tt class="py-line"> </tt>
<a name="L251"></a><tt class="py-lineno">251</tt>  <tt class="py-line"> </tt>
<a name="L252"></a><tt class="py-lineno">252</tt>  <tt class="py-line"> </tt>
<a name="L253"></a><tt class="py-lineno">253</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">PARAMS_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt> </tt>
<a name="L254"></a><tt class="py-lineno">254</tt>  <tt class="py-line">                <tt class="py-name">sb</tt> <tt class="py-op">=</tt> <tt class="py-name">sb</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ET</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ENVELOPE_TAG</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">CT</tt>  </tt>
<a name="L255"></a><tt class="py-lineno">255</tt>  <tt class="py-line">     </tt>
<a name="L256"></a><tt class="py-lineno">256</tt>  <tt class="py-line">                <tt class="py-keyword">return</tt> <tt class="py-name">sb</tt> </tt>
</div><a name="L257"></a><tt class="py-lineno">257</tt>  <tt class="py-line"> </tt>
<a name="L258"></a><tt class="py-lineno">258</tt>  <tt class="py-line">        <tt class="py-string">"""</tt> </tt>
<a name="L259"></a><tt class="py-lineno">259</tt>  <tt class="py-line"><tt class="py-string">         ***************************************************</tt> </tt>
<a name="L260"></a><tt class="py-lineno">260</tt>  <tt class="py-line"><tt class="py-string">         *               Decoding methods                  *</tt> </tt>
<a name="L261"></a><tt class="py-lineno">261</tt>  <tt class="py-line"><tt class="py-string">         ***************************************************</tt> </tt>
<a name="L262"></a><tt class="py-lineno">262</tt>  <tt class="py-line"><tt class="py-string">        """</tt> </tt>
<a name="L263"></a><tt class="py-lineno">263</tt>  <tt class="py-line">    </tt>
<a name="L264"></a><tt class="py-lineno">264</tt>  <tt class="py-line">        <tt class="py-comment">#This method is called when start the document XML</tt> </tt>
<a name="XMLCodec.startDocument"></a><div id="XMLCodec.startDocument-def"><a name="L265"></a><tt class="py-lineno">265</tt> <a class="py-toggle" href="#" id="XMLCodec.startDocument-toggle" onclick="return toggle('XMLCodec.startDocument');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#startDocument">startDocument</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.startDocument-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.startDocument-expanded"><a name="L266"></a><tt class="py-lineno">266</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt> <tt class="py-op">=</tt> <tt id="link-49" class="py-name"><a title="spade.Envelope
spade.Envelope.Envelope" class="py-name" href="#" onclick="return doclink('link-49', 'Envelope', 'link-4');">Envelope</a></tt><tt class="py-op">.</tt><tt id="link-50" class="py-name"><a title="spade.Envelope
spade.Envelope.Envelope" class="py-name" href="#" onclick="return doclink('link-50', 'Envelope', 'link-4');">Envelope</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
</div><a name="L267"></a><tt class="py-lineno">267</tt>  <tt class="py-line">   </tt>
<a name="L268"></a><tt class="py-lineno">268</tt>  <tt class="py-line">        <tt class="py-comment">#This method is called at the end of parsing */</tt> </tt>
<a name="XMLCodec.endDocument"></a><div id="XMLCodec.endDocument-def"><a name="L269"></a><tt class="py-lineno">269</tt> <a class="py-toggle" href="#" id="XMLCodec.endDocument-toggle" onclick="return toggle('XMLCodec.endDocument');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#endDocument">endDocument</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.endDocument-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.endDocument-expanded"><a name="L270"></a><tt class="py-lineno">270</tt>  <tt class="py-line">                <tt class="py-keyword">pass</tt> </tt>
</div><a name="L271"></a><tt class="py-lineno">271</tt>  <tt class="py-line">                <tt class="py-comment">#Put the ro object in to envelope</tt> </tt>
<a name="L272"></a><tt class="py-lineno">272</tt>  <tt class="py-line">                <tt class="py-comment">#env.setReceived(ro)</tt> </tt>
<a name="L273"></a><tt class="py-lineno">273</tt>  <tt class="py-line"> </tt>
<a name="L274"></a><tt class="py-lineno">274</tt>  <tt class="py-line">        <tt class="py-comment">#This method is called when jmp event of begin element.*/   </tt> </tt>
<a name="L275"></a><tt class="py-lineno">275</tt>  <tt class="py-line">        <tt class="py-comment">#def startElement(self, uri, localName, rawName, attributes):</tt> </tt>
<a name="XMLCodec.startElement"></a><div id="XMLCodec.startElement-def"><a name="L276"></a><tt class="py-lineno">276</tt> <a class="py-toggle" href="#" id="XMLCodec.startElement-toggle" onclick="return toggle('XMLCodec.startElement');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#startElement">startElement</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">localName</tt><tt class="py-op">,</tt> <tt class="py-param">attributes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.startElement-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.startElement-expanded"><a name="L277"></a><tt class="py-lineno">277</tt>  <tt class="py-line">                 </tt>
<a name="L278"></a><tt class="py-lineno">278</tt>  <tt class="py-line">                <tt class="py-comment">#Detection of the begin of to or from tags</tt> </tt>
<a name="L279"></a><tt class="py-lineno">279</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt> <tt class="py-op">=</tt> <tt class="py-string">""</tt> </tt>
<a name="L280"></a><tt class="py-lineno">280</tt>  <tt class="py-line">     </tt>
<a name="L281"></a><tt class="py-lineno">281</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L282"></a><tt class="py-lineno">282</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-51" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-51', 'aid', 'link-5');">aid</a></tt> <tt class="py-op">=</tt> <tt id="link-52" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-52', 'aid', 'link-5');">aid</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L283"></a><tt class="py-lineno">283</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt> </tt>
<a name="L284"></a><tt class="py-lineno">284</tt>  <tt class="py-line">                        <tt class="py-comment">#self.env.addTo(aid)</tt> </tt>
<a name="L285"></a><tt class="py-lineno">285</tt>  <tt class="py-line"> </tt>
<a name="L286"></a><tt class="py-lineno">286</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L287"></a><tt class="py-lineno">287</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-53" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-53', 'aid', 'link-5');">aid</a></tt> <tt class="py-op">=</tt> <tt id="link-54" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-54', 'aid', 'link-5');">aid</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L288"></a><tt class="py-lineno">288</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt> </tt>
<a name="L289"></a><tt class="py-lineno">289</tt>  <tt class="py-line">                        <tt class="py-comment">#self.env.setFrom(aid)</tt> </tt>
<a name="L290"></a><tt class="py-lineno">290</tt>  <tt class="py-line"> </tt>
<a name="L291"></a><tt class="py-lineno">291</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L292"></a><tt class="py-lineno">292</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-55" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-55', 'aid', 'link-5');">aid</a></tt> <tt class="py-op">=</tt> <tt id="link-56" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-56', 'aid', 'link-5');">aid</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L293"></a><tt class="py-lineno">293</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt> </tt>
<a name="L294"></a><tt class="py-lineno">294</tt>  <tt class="py-line">                        <tt class="py-comment">#self.env.addIntendedReceiver(self.aid)</tt> </tt>
<a name="L295"></a><tt class="py-lineno">295</tt>  <tt class="py-line"> </tt>
<a name="L296"></a><tt class="py-lineno">296</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L297"></a><tt class="py-lineno">297</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-57" class="py-name" targets="Method spade.Envelope.Envelope.setReceived()=spade.Envelope.Envelope-class.html#setReceived"><a title="spade.Envelope.Envelope.setReceived" class="py-name" href="#" onclick="return doclink('link-57', 'setReceived', 'link-57');">setReceived</a></tt><tt class="py-op">(</tt><tt id="link-58" class="py-name"><a title="spade.ReceivedObject
spade.ReceivedObject.ReceivedObject" class="py-name" href="#" onclick="return doclink('link-58', 'ReceivedObject', 'link-2');">ReceivedObject</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
<a name="L298"></a><tt class="py-lineno">298</tt>  <tt class="py-line">     </tt>
<a name="L299"></a><tt class="py-lineno">299</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_BY</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L300"></a><tt class="py-lineno">300</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt class="py-name">received</tt><tt class="py-op">.</tt><tt id="link-59" class="py-name" targets="Method spade.ReceivedObject.ReceivedObject.setBy()=spade.ReceivedObject.ReceivedObject-class.html#setBy"><a title="spade.ReceivedObject.ReceivedObject.setBy" class="py-name" href="#" onclick="return doclink('link-59', 'setBy', 'link-59');">setBy</a></tt><tt class="py-op">(</tt> <tt class="py-name">attributes</tt><tt class="py-op">.</tt><tt id="link-60" class="py-name" targets="Method spade.xmpp.protocol.DataField.getValue()=spade.xmpp.protocol.DataField-class.html#getValue"><a title="spade.xmpp.protocol.DataField.getValue" class="py-name" href="#" onclick="return doclink('link-60', 'getValue', 'link-60');">getValue</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L301"></a><tt class="py-lineno">301</tt>  <tt class="py-line"> </tt>
<a name="L302"></a><tt class="py-lineno">302</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_FROM</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L303"></a><tt class="py-lineno">303</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt class="py-name">received</tt><tt class="py-op">.</tt><tt id="link-61" class="py-name" targets="Method spade.Envelope.Envelope.setFrom()=spade.Envelope.Envelope-class.html#setFrom,Method spade.ReceivedObject.ReceivedObject.setFrom()=spade.ReceivedObject.ReceivedObject-class.html#setFrom,Method spade.xmpp.protocol.Protocol.setFrom()=spade.xmpp.protocol.Protocol-class.html#setFrom"><a title="spade.Envelope.Envelope.setFrom
spade.ReceivedObject.ReceivedObject.setFrom
spade.xmpp.protocol.Protocol.setFrom" class="py-name" href="#" onclick="return doclink('link-61', 'setFrom', 'link-61');">setFrom</a></tt><tt class="py-op">(</tt> <tt class="py-name">attributes</tt><tt class="py-op">.</tt><tt id="link-62" class="py-name"><a title="spade.xmpp.protocol.DataField.getValue" class="py-name" href="#" onclick="return doclink('link-62', 'getValue', 'link-60');">getValue</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L304"></a><tt class="py-lineno">304</tt>  <tt class="py-line"> </tt>
<a name="L305"></a><tt class="py-lineno">305</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_DATE</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L306"></a><tt class="py-lineno">306</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt class="py-name">received</tt><tt class="py-op">.</tt><tt id="link-63" class="py-name" targets="Method spade.Envelope.Envelope.setDate()=spade.Envelope.Envelope-class.html#setDate,Method spade.ReceivedObject.ReceivedObject.setDate()=spade.ReceivedObject.ReceivedObject-class.html#setDate"><a title="spade.Envelope.Envelope.setDate
spade.ReceivedObject.ReceivedObject.setDate" class="py-name" href="#" onclick="return doclink('link-63', 'setDate', 'link-63');">setDate</a></tt><tt class="py-op">(</tt> <tt id="link-64" class="py-name"><a title="spade.BasicFipaDateTime
spade.BasicFipaDateTime.BasicFipaDateTime" class="py-name" href="#" onclick="return doclink('link-64', 'BasicFipaDateTime', 'link-0');">BasicFipaDateTime</a></tt><tt class="py-op">(</tt> <tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">attributes</tt><tt class="py-op">.</tt><tt id="link-65" class="py-name"><a title="spade.xmpp.protocol.DataField.getValue" class="py-name" href="#" onclick="return doclink('link-65', 'getValue', 'link-60');">getValue</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L307"></a><tt class="py-lineno">307</tt>  <tt class="py-line"> </tt>
<a name="L308"></a><tt class="py-lineno">308</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ID</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L309"></a><tt class="py-lineno">309</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt class="py-name">received</tt><tt class="py-op">.</tt><tt id="link-66" class="py-name" targets="Method spade.ReceivedObject.ReceivedObject.setId()=spade.ReceivedObject.ReceivedObject-class.html#setId"><a title="spade.ReceivedObject.ReceivedObject.setId" class="py-name" href="#" onclick="return doclink('link-66', 'setId', 'link-66');">setId</a></tt><tt class="py-op">(</tt> <tt class="py-name">attributes</tt><tt class="py-op">.</tt><tt id="link-67" class="py-name"><a title="spade.xmpp.protocol.DataField.getValue" class="py-name" href="#" onclick="return doclink('link-67', 'getValue', 'link-60');">getValue</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L310"></a><tt class="py-lineno">310</tt>  <tt class="py-line"> </tt>
<a name="L311"></a><tt class="py-lineno">311</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_VIA</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L312"></a><tt class="py-lineno">312</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt class="py-name">received</tt><tt class="py-op">.</tt><tt id="link-68" class="py-name" targets="Method spade.ReceivedObject.ReceivedObject.setVia()=spade.ReceivedObject.ReceivedObject-class.html#setVia"><a title="spade.ReceivedObject.ReceivedObject.setVia" class="py-name" href="#" onclick="return doclink('link-68', 'setVia', 'link-68');">setVia</a></tt><tt class="py-op">(</tt> <tt class="py-name">attributes</tt><tt class="py-op">.</tt><tt id="link-69" class="py-name"><a title="spade.xmpp.protocol.DataField.getValue" class="py-name" href="#" onclick="return doclink('link-69', 'getValue', 'link-60');">getValue</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">RECEIVED_ATTR</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L313"></a><tt class="py-lineno">313</tt>  <tt class="py-line"> </tt>
<a name="L314"></a><tt class="py-lineno">314</tt>  <tt class="py-line">                <tt class="py-string">"""</tt> </tt>
<a name="L315"></a><tt class="py-lineno">315</tt>  <tt class="py-line"><tt class="py-string">                elif self.PROP_TAG.lower() == localName.lower():</tt> </tt>
<a name="L316"></a><tt class="py-lineno">316</tt>  <tt class="py-line"><tt class="py-string">                        prop = Property()</tt> </tt>
<a name="L317"></a><tt class="py-lineno">317</tt>  <tt class="py-line"><tt class="py-string">                        env.addProperties(prop)</tt> </tt>
<a name="L318"></a><tt class="py-lineno">318</tt>  <tt class="py-line"><tt class="py-string">                        prop.setName(attributes.getValue(self.PROP_ATTR))</tt> </tt>
<a name="L319"></a><tt class="py-lineno">319</tt>  <tt class="py-line"><tt class="py-string">                        propType = attributes.getValue(self.PROP_ATTR_TYPE)</tt> </tt>
<a name="L320"></a><tt class="py-lineno">320</tt>  <tt class="py-line"><tt class="py-string">                """</tt> </tt>
</div><a name="L321"></a><tt class="py-lineno">321</tt>  <tt class="py-line">   </tt>
<a name="L322"></a><tt class="py-lineno">322</tt>  <tt class="py-line">        <tt class="py-comment">#This method is called the end of element</tt> </tt>
<a name="L323"></a><tt class="py-lineno">323</tt>  <tt class="py-line">        <tt class="py-comment">#def endElement(self, namespaceURL, localName, qname):</tt> </tt>
<a name="XMLCodec.endElement"></a><div id="XMLCodec.endElement-def"><a name="L324"></a><tt class="py-lineno">324</tt> <a class="py-toggle" href="#" id="XMLCodec.endElement-toggle" onclick="return toggle('XMLCodec.endElement');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#endElement">endElement</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">localName</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.endElement-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.endElement-expanded"><a name="L325"></a><tt class="py-lineno">325</tt>  <tt class="py-line">     </tt>
<a name="L326"></a><tt class="py-lineno">326</tt>  <tt class="py-line">                <tt class="py-comment">#Capture the value the attributes of class</tt> </tt>
<a name="L327"></a><tt class="py-lineno">327</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_NAME</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L328"></a><tt class="py-lineno">328</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-70" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-70', 'aid', 'link-5');">aid</a></tt><tt class="py-op">.</tt><tt id="link-71" class="py-name" targets="Method spade.AID.aid.setName()=spade.AID.aid-class.html#setName,Method spade.DF.Service.setName()=spade.DF.Service-class.html#setName,Method spade.DF.ServiceDescription.setName()=spade.DF.ServiceDescription-class.html#setName,Method spade.pyparsing.ParserElement.setName()=spade.pyparsing.ParserElement-class.html#setName,Method spade.pyparsing.Token.setName()=spade.pyparsing.Token-class.html#setName,Method spade.xmpp.simplexml.Node.setName()=spade.xmpp.simplexml.Node-class.html#setName,Method spade.xmppd.modules.muc.Room.setName()=spade.xmppd.modules.muc.Room-class.html#setName,Method spade.xmppd.modules.wq.Group.setName()=spade.xmppd.modules.wq.Group-class.html#setName"><a title="spade.AID.aid.setName
spade.DF.Service.setName
spade.DF.ServiceDescription.setName
spade.pyparsing.ParserElement.setName
spade.pyparsing.Token.setName
spade.xmpp.simplexml.Node.setName
spade.xmppd.modules.muc.Room.setName
spade.xmppd.modules.wq.Group.setName" class="py-name" href="#" onclick="return doclink('link-71', 'setName', 'link-71');">setName</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt> </tt>
<a name="L329"></a><tt class="py-lineno">329</tt>  <tt class="py-line"> </tt>
<a name="L330"></a><tt class="py-lineno">330</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_ADDRESS</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L331"></a><tt class="py-lineno">331</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-72" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-72', 'aid', 'link-5');">aid</a></tt><tt class="py-op">.</tt><tt id="link-73" class="py-name" targets="Method spade.AID.aid.addAddress()=spade.AID.aid-class.html#addAddress,Method spade.Agent.AbstractAgent.addAddress()=spade.Agent.AbstractAgent-class.html#addAddress"><a title="spade.AID.aid.addAddress
spade.Agent.AbstractAgent.addAddress" class="py-name" href="#" onclick="return doclink('link-73', 'addAddress', 'link-73');">addAddress</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt> </tt>
<a name="L332"></a><tt class="py-lineno">332</tt>  <tt class="py-line"> </tt>
<a name="L333"></a><tt class="py-lineno">333</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L334"></a><tt class="py-lineno">334</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">=</tt> <tt class="py-string">""</tt> </tt>
<a name="L335"></a><tt class="py-lineno">335</tt>  <tt class="py-line"> </tt>
<a name="L336"></a><tt class="py-lineno">336</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L337"></a><tt class="py-lineno">337</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">=</tt> <tt class="py-string">""</tt> </tt>
<a name="L338"></a><tt class="py-lineno">338</tt>  <tt class="py-line"> </tt>
<a name="L339"></a><tt class="py-lineno">339</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L340"></a><tt class="py-lineno">340</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">=</tt> <tt class="py-string">""</tt> </tt>
<a name="L341"></a><tt class="py-lineno">341</tt>  <tt class="py-line"> </tt>
<a name="L342"></a><tt class="py-lineno">342</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">AID_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L343"></a><tt class="py-lineno">343</tt>  <tt class="py-line">                        <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">==</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">TO_TAG</tt><tt class="py-op">:</tt> </tt>
<a name="L344"></a><tt class="py-lineno">344</tt>  <tt class="py-line">                                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-74" class="py-name" targets="Method spade.Envelope.Envelope.addTo()=spade.Envelope.Envelope-class.html#addTo"><a title="spade.Envelope.Envelope.addTo" class="py-name" href="#" onclick="return doclink('link-74', 'addTo', 'link-74');">addTo</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-75" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-75', 'aid', 'link-5');">aid</a></tt><tt class="py-op">)</tt> </tt>
<a name="L345"></a><tt class="py-lineno">345</tt>  <tt class="py-line">                        <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">==</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">FROM_TAG</tt><tt class="py-op">:</tt> </tt>
<a name="L346"></a><tt class="py-lineno">346</tt>  <tt class="py-line">                                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-76" class="py-name"><a title="spade.Envelope.Envelope.setFrom
spade.ReceivedObject.ReceivedObject.setFrom
spade.xmpp.protocol.Protocol.setFrom" class="py-name" href="#" onclick="return doclink('link-76', 'setFrom', 'link-61');">setFrom</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-77" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-77', 'aid', 'link-5');">aid</a></tt><tt class="py-op">)</tt> </tt>
<a name="L347"></a><tt class="py-lineno">347</tt>  <tt class="py-line">                        <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">aidTag</tt> <tt class="py-op">==</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">INTENDED_TAG</tt><tt class="py-op">:</tt> </tt>
<a name="L348"></a><tt class="py-lineno">348</tt>  <tt class="py-line">                                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-78" class="py-name" targets="Method spade.Envelope.Envelope.addIntendedReceiver()=spade.Envelope.Envelope-class.html#addIntendedReceiver"><a title="spade.Envelope.Envelope.addIntendedReceiver" class="py-name" href="#" onclick="return doclink('link-78', 'addIntendedReceiver', 'link-78');">addIntendedReceiver</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-79" class="py-name"><a title="spade.AID.aid" class="py-name" href="#" onclick="return doclink('link-79', 'aid', 'link-5');">aid</a></tt><tt class="py-op">)</tt> </tt>
<a name="L349"></a><tt class="py-lineno">349</tt>  <tt class="py-line"> </tt>
<a name="L350"></a><tt class="py-lineno">350</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">COMMENTS_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L351"></a><tt class="py-lineno">351</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-80" class="py-name" targets="Method spade.Envelope.Envelope.setComments()=spade.Envelope.Envelope-class.html#setComments"><a title="spade.Envelope.Envelope.setComments" class="py-name" href="#" onclick="return doclink('link-80', 'setComments', 'link-80');">setComments</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt> </tt>
<a name="L352"></a><tt class="py-lineno">352</tt>  <tt class="py-line"> </tt>
<a name="L353"></a><tt class="py-lineno">353</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">REPRESENTATION_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L354"></a><tt class="py-lineno">354</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-81" class="py-name" targets="Method spade.Envelope.Envelope.setAclRepresentation()=spade.Envelope.Envelope-class.html#setAclRepresentation"><a title="spade.Envelope.Envelope.setAclRepresentation" class="py-name" href="#" onclick="return doclink('link-81', 'setAclRepresentation', 'link-81');">setAclRepresentation</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt> </tt>
<a name="L355"></a><tt class="py-lineno">355</tt>  <tt class="py-line"> </tt>
<a name="L356"></a><tt class="py-lineno">356</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">LENGTH_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L357"></a><tt class="py-lineno">357</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-82" class="py-name" targets="Method spade.Envelope.Envelope.setPayloadLength()=spade.Envelope.Envelope-class.html#setPayloadLength"><a title="spade.Envelope.Envelope.setPayloadLength" class="py-name" href="#" onclick="return doclink('link-82', 'setPayloadLength', 'link-82');">setPayloadLength</a></tt><tt class="py-op">(</tt> <tt class="py-name">long</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
<a name="L358"></a><tt class="py-lineno">358</tt>  <tt class="py-line">                        <tt class="py-string">"""</tt> </tt>
<a name="L359"></a><tt class="py-lineno">359</tt>  <tt class="py-line"><tt class="py-string">                        if(logger.isLoggable(Logger.WARNING))</tt> </tt>
<a name="L360"></a><tt class="py-lineno">360</tt>  <tt class="py-line"><tt class="py-string">                                logger.log(Logger.FINE,"Length: "+env.getPayloadLength());</tt> </tt>
<a name="L361"></a><tt class="py-lineno">361</tt>  <tt class="py-line"><tt class="py-string">                        """</tt> </tt>
<a name="L362"></a><tt class="py-lineno">362</tt>  <tt class="py-line"> </tt>
<a name="L363"></a><tt class="py-lineno">363</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">ENCODING_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt><tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L364"></a><tt class="py-lineno">364</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-83" class="py-name" targets="Method spade.Envelope.Envelope.setPayloadEncoding()=spade.Envelope.Envelope-class.html#setPayloadEncoding"><a title="spade.Envelope.Envelope.setPayloadEncoding" class="py-name" href="#" onclick="return doclink('link-83', 'setPayloadEncoding', 'link-83');">setPayloadEncoding</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt> </tt>
<a name="L365"></a><tt class="py-lineno">365</tt>  <tt class="py-line"> </tt>
<a name="L366"></a><tt class="py-lineno">366</tt>  <tt class="py-line">                <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">DATE_TAG</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">localName</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L367"></a><tt class="py-lineno">367</tt>  <tt class="py-line">                        <tt class="py-name">bfdt</tt><tt class="py-op">=</tt> <tt id="link-84" class="py-name"><a title="spade.BasicFipaDateTime
spade.BasicFipaDateTime.BasicFipaDateTime" class="py-name" href="#" onclick="return doclink('link-84', 'BasicFipaDateTime', 'link-0');">BasicFipaDateTime</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L368"></a><tt class="py-lineno">368</tt>  <tt class="py-line">                        <tt class="py-name">bfdt</tt><tt class="py-op">.</tt><tt id="link-85" class="py-name"><a title="spade.BasicFipaDateTime.BasicFipaDateTime.fromString" class="py-name" href="#" onclick="return doclink('link-85', 'fromString', 'link-32');">fromString</a></tt><tt class="py-op">(</tt><tt class="py-name">str</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
<a name="L369"></a><tt class="py-lineno">369</tt>  <tt class="py-line">                        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt><tt class="py-op">.</tt><tt id="link-86" class="py-name"><a title="spade.Envelope.Envelope.setDate
spade.ReceivedObject.ReceivedObject.setDate" class="py-name" href="#" onclick="return doclink('link-86', 'setDate', 'link-63');">setDate</a></tt><tt class="py-op">(</tt> <tt class="py-name">bfdt</tt> <tt class="py-op">)</tt> </tt>
<a name="L370"></a><tt class="py-lineno">370</tt>  <tt class="py-line"> </tt>
<a name="L371"></a><tt class="py-lineno">371</tt>  <tt class="py-line">                <tt class="py-string">"""</tt> </tt>
<a name="L372"></a><tt class="py-lineno">372</tt>  <tt class="py-line"><tt class="py-string">                elif self.PROP_TAG.lower() == localName.lower():</tt> </tt>
<a name="L373"></a><tt class="py-lineno">373</tt>  <tt class="py-line"><tt class="py-string">                        decodeProp(accumulator, prop);</tt> </tt>
<a name="L374"></a><tt class="py-lineno">374</tt>  <tt class="py-line"><tt class="py-string">                """</tt> </tt>
<a name="L375"></a><tt class="py-lineno">375</tt>  <tt class="py-line">                <tt class="py-string">""" </tt> </tt>
<a name="L376"></a><tt class="py-lineno">376</tt>  <tt class="py-line"><tt class="py-string">                #Not sure it is still in FIPA</tt> </tt>
<a name="L377"></a><tt class="py-lineno">377</tt>  <tt class="py-line"><tt class="py-string">                elif self.ENCRYPTED_TAG.lower() == localName.low():</tt> </tt>
<a name="L378"></a><tt class="py-lineno">378</tt>  <tt class="py-line"><tt class="py-string">                        self.env.addEncrypted(accumulator)</tt> </tt>
<a name="L379"></a><tt class="py-lineno">379</tt>  <tt class="py-line"><tt class="py-string">                """</tt> </tt>
</div><a name="L380"></a><tt class="py-lineno">380</tt>  <tt class="py-line">   </tt>
<a name="L381"></a><tt class="py-lineno">381</tt>  <tt class="py-line">        <tt class="py-comment">#This method is called when exist characters in the elements</tt> </tt>
<a name="XMLCodec.characters"></a><div id="XMLCodec.characters-def"><a name="L382"></a><tt class="py-lineno">382</tt> <a class="py-toggle" href="#" id="XMLCodec.characters-toggle" onclick="return toggle('XMLCodec.characters');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#characters">characters</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">buff</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.characters-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.characters-expanded"><a name="L383"></a><tt class="py-lineno">383</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">accumulator</tt> <tt class="py-op">+</tt> <tt class="py-name">buff</tt> </tt>
</div><a name="L384"></a><tt class="py-lineno">384</tt>  <tt class="py-line">   </tt>
<a name="L385"></a><tt class="py-lineno">385</tt>  <tt class="py-line">        <tt class="py-string">"""</tt> </tt>
<a name="L386"></a><tt class="py-lineno">386</tt>  <tt class="py-line"><tt class="py-string">        /** This method is called when warning occur*/  </tt> </tt>
<a name="L387"></a><tt class="py-lineno">387</tt>  <tt class="py-line"><tt class="py-string">        public void warning(SAXParseException exception) {</tt> </tt>
<a name="L388"></a><tt class="py-lineno">388</tt>  <tt class="py-line"><tt class="py-string">        if(logger.isLoggable(Logger.WARNING))</tt> </tt>
<a name="L389"></a><tt class="py-lineno">389</tt>  <tt class="py-line"><tt class="py-string">        logger.log(Logger.WARNING," line " + exception.getLineNumber() + ": "+</tt> </tt>
<a name="L390"></a><tt class="py-lineno">390</tt>  <tt class="py-line"><tt class="py-string">                   exception.getMessage());</tt> </tt>
<a name="L391"></a><tt class="py-lineno">391</tt>  <tt class="py-line"><tt class="py-string">        }</tt> </tt>
<a name="L392"></a><tt class="py-lineno">392</tt>  <tt class="py-line"><tt class="py-string">  </tt> </tt>
<a name="L393"></a><tt class="py-lineno">393</tt>  <tt class="py-line"><tt class="py-string">        /** This method is called when errors occur*/ </tt> </tt>
<a name="L394"></a><tt class="py-lineno">394</tt>  <tt class="py-line"><tt class="py-string">        public void error(SAXParseException exception)  {</tt> </tt>
<a name="L395"></a><tt class="py-lineno">395</tt>  <tt class="py-line"><tt class="py-string">        if(logger.isLoggable(Logger.WARNING))</tt> </tt>
<a name="L396"></a><tt class="py-lineno">396</tt>  <tt class="py-line"><tt class="py-string">        logger.log(Logger.WARNING,"ERROR: line " + exception.getLineNumber() + ": " +</tt> </tt>
<a name="L397"></a><tt class="py-lineno">397</tt>  <tt class="py-line"><tt class="py-string">                       exception.getMessage());</tt> </tt>
<a name="L398"></a><tt class="py-lineno">398</tt>  <tt class="py-line"><tt class="py-string">        }</tt> </tt>
<a name="L399"></a><tt class="py-lineno">399</tt>  <tt class="py-line"><tt class="py-string">  </tt> </tt>
<a name="L400"></a><tt class="py-lineno">400</tt>  <tt class="py-line"><tt class="py-string">        /** This method is called when non-recoverable errors occur.*/ </tt> </tt>
<a name="L401"></a><tt class="py-lineno">401</tt>  <tt class="py-line"><tt class="py-string">        public void fatalError(SAXParseException exception) throws SAXException{</tt> </tt>
<a name="L402"></a><tt class="py-lineno">402</tt>  <tt class="py-line"><tt class="py-string">        if(logger.isLoggable(Logger.WARNING))</tt> </tt>
<a name="L403"></a><tt class="py-lineno">403</tt>  <tt class="py-line"><tt class="py-string">        logger.log(Logger.SEVERE,"FATAL: line " + exception.getLineNumber() + ": " +</tt> </tt>
<a name="L404"></a><tt class="py-lineno">404</tt>  <tt class="py-line"><tt class="py-string">                       exception.getMessage());</tt> </tt>
<a name="L405"></a><tt class="py-lineno">405</tt>  <tt class="py-line"><tt class="py-string">        throw exception;</tt> </tt>
<a name="L406"></a><tt class="py-lineno">406</tt>  <tt class="py-line"><tt class="py-string">        }</tt> </tt>
<a name="L407"></a><tt class="py-lineno">407</tt>  <tt class="py-line"><tt class="py-string">        """</tt> </tt>
<a name="L408"></a><tt class="py-lineno">408</tt>  <tt class="py-line"> </tt>
<a name="L409"></a><tt class="py-lineno">409</tt>  <tt class="py-line">        <tt class="py-comment"># Main method #</tt> </tt>
<a name="XMLCodec.parse"></a><div id="XMLCodec.parse-def"><a name="L410"></a><tt class="py-lineno">410</tt> <a class="py-toggle" href="#" id="XMLCodec.parse-toggle" onclick="return toggle('XMLCodec.parse');">-</a><tt class="py-line">        <tt class="py-keyword">def</tt> <a class="py-def-name" href="spade.XMLCodec.XMLCodec-class.html#parse">parse</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">_in</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="XMLCodec.parse-collapsed" style="display:none;" pad="+++" indent="++++++++++++"></div><div id="XMLCodec.parse-expanded"><a name="L411"></a><tt class="py-lineno">411</tt>  <tt class="py-line">            <tt class="py-docstring">"""</tt> </tt>
<a name="L412"></a><tt class="py-lineno">412</tt>  <tt class="py-line"><tt class="py-docstring">            parses the xml input</tt> </tt>
<a name="L413"></a><tt class="py-lineno">413</tt>  <tt class="py-line"><tt class="py-docstring">            """</tt> </tt>
<a name="L414"></a><tt class="py-lineno">414</tt>  <tt class="py-line">            <tt class="py-name">xml</tt><tt class="py-op">.</tt><tt class="py-name">sax</tt><tt class="py-op">.</tt><tt id="link-87" class="py-name" targets="Method spade.SpadeConfigParser.spadeXML.parseString()=spade.SpadeConfigParser.spadeXML-class.html#parseString,Method spade.pyparsing.ParserElement.parseString()=spade.pyparsing.ParserElement-class.html#parseString,Method spade.xmppd.modules.config.xmppdXML.parseString()=spade.xmppd.modules.config.xmppdXML-class.html#parseString"><a title="spade.SpadeConfigParser.spadeXML.parseString
spade.pyparsing.ParserElement.parseString
spade.xmppd.modules.config.xmppdXML.parseString" class="py-name" href="#" onclick="return doclink('link-87', 'parseString', 'link-87');">parseString</a></tt><tt class="py-op">(</tt><tt class="py-name">_in</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
<a name="L415"></a><tt class="py-lineno">415</tt>  <tt class="py-line">            <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">env</tt> </tt>
</div></div><a name="L416"></a><tt class="py-lineno">416</tt>  <tt class="py-line"> </tt><script type="text/javascript">
<!--
expandto(location.href);
// -->
</script>
</pre>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="spade-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://spade2.googlecode.com">SPADE</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Wed Aug  1 18:45:06 2012
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
